<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>

        div{
            width: 200px;
            height: 200px;
        }
        .box{
            background-color: rosybrown;
        }
        .box1{
            background-color: salmon;
        }
    </style>
</head>
<body>

    <div id="app">
        <div class="box" v-show="flag"></div>
        <div class="box1" v-if="flag1"></div>


		<!-- v-if可以作为条判断语句 -->
        <p v-if="score >= 90">优秀</p>
        <p v-else-if="score >=80">良好</p>
        <p v-else-if="score >=60">及格</p>
        <p v-else>不及格</p>

		<!-- v-if可以控制多标签的显示和隐藏 -->
        <ul v-if="flag2">
            <li>1</li>
            <li>2</li>
            <li>3</li>
            <li>4</li>
            <li>5</li>
        </ul>
    </div>    

    <script src="../lib/Vue/vue.js"></script>
    <script>

        var vm = new Vue({
            el: '#app',
            data: {
                flag: true,
                flag1: true,
                score: 58,
                flag2: false
            }
        })
    </script>
</body>
</html>